package com.luck.emp.storage.logic;

import java.util.List;

import com.luck.emp.entity.EmpTCgM;
import com.luck.emp.entity.EmpTWhExM;
import com.luck.emp.storage.qry.StorageQry;
import com.luck.emp.storage.vo.StorageCheck;
import com.luck.emp.storage.vo.StorageCheckDetail;
import com.luck.pf.common.entity.UserBean;
import com.luck.pf.framework.logic.IBaseLogic;

/**
 * 说明 Copyright: Copyright (c) 2011 深圳**科技
 * 
 * @author
 * 
 */
public interface IStorageLogic extends IBaseLogic {
	/**
	 * 查询需要入库确认的单据
	 */
	public <T> T findStorageCheckPage(StorageQry qry, Class<T> cls);

	/**
	 * 根据billType，查找所有需要入库确认的单据，billType=11为采购单
	 * 
	 * @param qry
	 * @return
	 */
	public List<StorageCheckDetail> findStorageCheckDetailPage(StorageQry qry);
	/**
	 * 确认入库
	 * @param userInfo 
	 * @param cgm 采购单主表
	 * @param check 入库确认主表-临时表
	 * @param whCode 仓库代码
	 * @param exDIds 入库确认明细表id
	 * @param productCodes 商品编码
	 * @param stayInQtys 待入库数
	 * @param inQtys 实际入仓数
	 * @param realPrices 真实价格
	 * @param flowStatus 状态：完结
	 * @param ioType 出入库类型
	 * @param channelType 渠道
	 * @param custId 客户ID
	 * @param expnoId 详情单ID
	 * @return
	 * @throws Exception
	 */
	public String saveStorageCheckCg(UserBean userInfo, EmpTCgM cgm,
			StorageCheck check, String whCode, Long[] exDIds,
			String[] productCodes, String[] stayInQtys, String[] inQtys,
			String[] realPrices, String flowStatus, String ioType,
			String channelType, Long custId, Long salemanId) throws Exception;
	
	public String saveStorageCheckEx(UserBean userInfo, EmpTWhExM exm,
			StorageCheck check, String whCode, Long[] exDIds,
			String[] productCodes, String[] stayInQtys, String[] inQtys, String flowStatus, String ioType,
			String channelType, Long custId, Long salemanId) throws Exception;
}